package util
{
	import flash.display.DisplayObject;
	import flash.display.Sprite;
	import flash.events.MouseEvent;
	
	public class Button extends Sprite
	{
		private var _type:int;
		private var _ui:UIButton;
		
		public function Button(type:int=0, text:String="")
		{
			buttonMode = true;
			_type = type;
			
			_ui = new UIButton;
			_ui.mouseEnabled = _ui.mouseChildren = false;
			addChild(_ui);
			
			if (text != ""){
				_ui.txt.text = text;
			}
		}
		
		private function onClick(e:MouseEvent):void
		{
			// TODO Auto-generated method stub
		}
		
		public function set type(value:int):void{
			_type = value;
		}
		
		public function get type():int{
			return _type;
		}
	}
}